<?php

return [
    'default' => 'redis',
    'stores' => [
        'redis' => [
            // 驱动方式
            'type'   => 'redis',
            // 服务器地址
            'host'       => '127.0.0.1',
            // 端口
            'port'       => '26379',

            // 哨兵名称
            'sentinel_name' => '', //redis 是否使用哨兵 不使用 为空否则即填哨兵名称

            //
            'options' => [
                'connect_timeout' => 2,
                'timeout' => 30,
                'serialize' => true,
                'reconnect' => 5,
                'compatibility_mode' => true
            ],
        ],
        'file' => [
            'type' => 'file',
            'path' => runtime_path() . 'store' . DIRECTORY_SEPARATOR,
            // second
            'expired' => 60
        ],
        'session' => [
            'type' => 'file',
            'path' => runtime_path() . 'store' . DIRECTORY_SEPARATOR . 'session' . DIRECTORY_SEPARATOR,
            // second
            'expired' => 84600
        ],
    ],
];
